/*
 * @Author: scopesang
 * @Date: 2022-05-10 13:40:04
 * @LastEditors: scopesang
 * @LastEditTime: 2022-05-10 13:45:55
 * @FilePath: \TypeScript\src\interface\type.ts
 * @Description:// 接口类型
 *
 * Copyright (c) 2022 by scopesang/大鹏科技, All Rights Reserved.
 */
// 使用接口定义字段的类型
// 接口一般首字母大写 经常用 i 开头
interface IOBJ { name: string, age: number }
function fn(obj: IOBJ): void {
    console.log(`${obj.name}${obj.age}`);
}


fn({ name: "44", age: 16 })